<!DOCTYPE html>
<html>

	<head>
		<meta charset="utf-8">
		<meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no" />
		<title></title>
		<link href="css/mui.min.css" rel="stylesheet" />
		<style>
	    	.mui-bar-nav{background: #71bb9a;}
	    	.mui-title{color:#fff;font-size: 1.2rem;}
	    	.mui-bar-tab .mui-tab-item{background: #71bb9a;color:#fff;}
			.mui-bar-tab .mui-tab-item.mui-active {
			    color: red;
			}
		   
		</style>
	</head>

	<body style="padding-bottom: 4rem;">
		<header class="mui-bar mui-bar-nav">
		    <h1 class="mui-title">高青电力感知平台</h1>
		</header>
	<div class="mui-content">
			
	</div>
	<nav class="mui-bar mui-bar-tab">
	    <a class="mui-tab-item mui-active" style="border-right: 2px solid #fff;" id="home">
	        <span class="mui-icon mui-icon-home"></span>
	        <!--<span class="mui-tab-label">首页</span>-->
	    </a>
	    <a class="mui-tab-item" href="" id="myinfo">
	        <span class="mui-icon mui-icon-person"></span>
	        <!--<span class="mui-tab-label">电话</span>-->
	    </a>
	</nav>
		<script src="js/mui.min.js"></script>
		<script src="js/app.js"></script>
		<script src="js/echarts.min.js"></script>
		<script src="js/public.js"></script>
		<script>
			(function($, doc) {
				$.init({
					gestureConfig:{
						doubletap:true
					},
					subpages:[{
						url:'main_list.html',
						id:'main_list',
						styles:{
							top: '45px',
							bottom: '50px',
						}
					}]
				});
			
				//
				doc.getElementById('myinfo').addEventListener('tap',function(){
					mui.openWindow({
							url:"examples/per_information.html",
							id:"per_information",
							style:{},
							show:{
								autoShow:true,
								aniShow:"slide-in-right",
								duration:100
							},
							waiting:{
								autoShow:true,
								title:"正在加载·····",
								options:{
								}
							}
					})
				});
				//
				var contentWebview = null;
				document.querySelector('header').addEventListener('doubletap',function () {
					if(contentWebview==null){
						contentWebview = plus.webview.currentWebview().children()[0];
					}
					contentWebview.evalJS("mui('#pullrefresh').pullRefresh().scrollTo(0,0,100)");
				});
				var settings = app.getSettings();
				var account = doc.getElementById('account');
				//
				//
				
				
				//
				//消息跳转
				window.addEventListener('show', function() {
					var state = app.getState();
					account.innerText = state.account;
				}, false);
				$.plusReady(function() {
					
					//--
					$.oldBack = mui.back;
					var backButtonPress = 0;
					$.back = function(event) {
						backButtonPress++;
						if (backButtonPress > 1) {
							plus.runtime.quit();
						} else {
							plus.nativeUI.toast('再按一次退出应用');
						}
						setTimeout(function() {
							backButtonPress = 0;
						}, 1000);
						return false;
					};
				});
				
			}(mui, document));
		</script>
	</body>

</html>